﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using DeepTime.BootStrapper.UploadedImageMetaData;
using DeepTime.BootStrapper.DeepTimeImageMetaData;
using DeepTime.BootStrapper.Collages;

namespace DeepTime.BootStrapper.Utilities
{
    public class ServiceHelper
    {
        /// <summary>
        /// Creates a proxy class with using a path relative to where the application is currently hosted.
        /// </summary>
        public static UploadedImageMetaDataClient CreateUploadedImageMetaDataProxy()
        {
            Uri ServiceUri = new Uri(App.Current.Host.Source, "../Services/UploadedImageMetaData.svc");
            return new UploadedImageMetaDataClient("CustomBinding_UploadedImageMetaData", ServiceUri.AbsoluteUri);
        }

        /// <summary>
        /// Creates a proxy class with using a path relative to where the application is currently hosted.
        /// </summary>
        public static DeepTimeImageMetaDataClient CreateDeepZoomImageMetaDataProxy()
        {
            Uri ServiceUri = new Uri(App.Current.Host.Source, "../Services/DeepTimeImageMetaData.svc");
            return new DeepTimeImageMetaDataClient("CustomBinding_DeepTimeImageMetaData", ServiceUri.AbsoluteUri);
        }

        /// <summary>
        /// Creates a proxy class with using a path relative to where the application is currently hosted.
        /// </summary>
        public static CollagesClient CreateCollagesProxy()
        {
            Uri ServiceUri = new Uri(App.Current.Host.Source, "../Services/Collages.svc");
            return new CollagesClient("CustomBinding_Collages", ServiceUri.AbsoluteUri);
        }
    }
}
